package com.sxyjhh.fg_data_push;

import com.sxyjhh.fg_data_push.service.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping(value = "/service")
public class TestWSDL {



    @Autowired
    private PushDataManager pushDataManager;


   /* @RequestMapping(value = "/fg", method = RequestMethod.GET)
    public String getById(@RequestParam(value = "type", required = false, defaultValue = "12") String type) {
        //获取当前操作人信息
       // IOtherProContract otherProContract = otherProService.getBasicHttpBindingIOtherProContract();
      //  String registerPersonInfo = otherProContract.getRegisterPersonInfo("{\"StartTime\":\"\",\"EndTime\":\"\",\"PersonType\":\""+type+"\",\"PageIndex\":\"1\",\"PageSize\":\"1\",\"UserName\":\"admin\",\"UserPwd\":\"123456\"}");

        if("06-02".equals(type)){
            dataExchangeService.startSynData2();
        }
        if("12".equals(type)){
            dataExchangeService.startSynData();
        }


        return "";
        // return registerPersonInfo;
    }
    @RequestMapping(value = "/cd", method = RequestMethod.GET)
    public String creditInquiry(@RequestParam(value = "type", required = false, defaultValue = "qy") String type) {
        creditInquiryService.dealCreditInfo(type);
        return  "";
    }*/
    @RequestMapping(value = "/test", method = RequestMethod.GET)
    public String creditInquiry() throws Exception {
        pushDataManager.pushCreditData();
        return  "";
    }

   /* @RequestMapping(value = "/testJk", method = RequestMethod.GET)
    public String testFdc() throws Exception {
        pushDataHlwJg.pushData();
        return  "";
    }
    @RequestMapping(value = "/testKCSJ", method = RequestMethod.GET)
    public String testKCSJ() throws Exception {
        pushDataKCSJ.pushData();
        return  "";
    }
    @RequestMapping(value = "/testJZY", method = RequestMethod.GET)
    public String testJZY() throws Exception {
        pushDataJZY.pushData();
        return  "";
    }*/


}
